<template>
    <div class="alertinfo">
        <div class="test">{{alertMsg}}</div>
    </div>
</template>
<script>
export default {
    name:'laertinfo',
    data(){
        return {
            alertMsg:'已添加到购物车'
        }
    }
}
</script>
<style scoped>
.alertinfo{
    position: fixed;
    top:400px;
    left: 50%;
    border-radius: 15px;
    transform: translate(-50%);
    padding: 5px;
    background-color: rgba(0, 0, 0, .5);
}
.test{
    color: rgb(255, 255, 255);
    font-size: 16px;
    text-align: center;
    line-height: 50px;
}
</style>